//
//  ZFK_buttonView.m
//  Drops
//
//  Created by SHG on 16/6/1.
//  Copyright © 2016年 Drops.er. All rights reserved.
//

#import "ZFK_buttonView.h"

@implementation ZFK_buttonView

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

- (id)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        [self createView];
    }
    return self;
}

- (void)createView {
    self.loginBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    self.loginBtn.frame = CGRectMake(sWIDTH / 4, 40, sWIDTH / 2, sWIDTH / 10);
    [self.loginBtn setTitle:@"登录" forState:0];
    self.loginBtn.backgroundColor = [UIColor colorWithRed:159 / 255.0 green:122 / 255.0 blue:121 / 255.0 alpha:1];
    [self.loginBtn setTitleColor:[UIColor whiteColor] forState:0];
    [self addSubview:self.loginBtn];
    
    self.registBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    self.registBtn.frame = CGRectMake(sWIDTH / 4, 40 + sWIDTH / 10 + 40, sWIDTH / 2, sWIDTH / 10);
    [self.registBtn setTitle:@"注册" forState:0];
    self.registBtn.backgroundColor = [UIColor colorWithRed:159 / 255.0 green:122 / 255.0 blue:121 / 255.0 alpha:1];
    [self.registBtn setTitleColor:[UIColor whiteColor] forState:0];
    [self addSubview:self.registBtn];
    
    self.backBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    self.backBtn.frame = CGRectMake(sWIDTH / 4, 80 + sWIDTH / 10 * 2 + 40, sWIDTH / 2, sWIDTH / 10);
    [self.backBtn setTitle:@"返回" forState:0];
    self.backBtn.backgroundColor = [UIColor colorWithRed:159 / 255.0 green:122 / 255.0 blue:121 / 255.0 alpha:1];
    [self.backBtn setTitleColor:[UIColor whiteColor] forState:0];
    [self addSubview:self.backBtn];
}

@end
